﻿<UserControl x:Class="JsAndSilverLight.MaiTips"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
        xmlns:esri="clr-namespace:ESRI.ArcGIS.Client;assembly=ESRI.ArcGIS.Client"
    xmlns:esriSymbols="clr-namespace:ESRI.ArcGIS.Client.Symbols;assembly=ESRI.ArcGIS.Client"
    xmlns:esriToolkit="clr-namespace:ESRI.ArcGIS.Client.Toolkit;assembly=ESRI.ArcGIS.Client.Toolkit">
    
    <Grid x:Name="LayoutRoot">

        <Grid.Resources>
            <esriSymbols:SimpleFillSymbol x:Name="DefaultFillSymbol" Fill="#01FFFFFF" BorderBrush="#88000000" BorderThickness="2" />
        </Grid.Resources>

        <esri:Map x:Name="MyMap" Background="White" Extent="-130,10,-70,60">
            <esri:Map.Layers>
                <esri:ArcGISTiledMapServiceLayer ID="BaseMapLayer" 
                    Url="http://server.arcgisonline.com/ArcGIS/rest/services/NGS_Topo_US_2D/MapServer" />
                <esri:GraphicsLayer ID="MyGraphicsLayer" Initialized="MyGraphicsLayer_Initialized" />
            </esri:Map.Layers>
        </esri:Map>

        <Grid HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0,10,10,0" >
            <Rectangle RadiusX="10" RadiusY="10" Fill="#22000000" Margin="0,4,0,0" />
            <Rectangle Stroke="Gray"  RadiusX="10" RadiusY="10" Fill="#775C90B2" Margin="0,0,0,5" />
            <Rectangle Fill="#FFFFFFFF" Stroke="DarkGray" RadiusX="5" RadiusY="5" Margin="10,10,10,15" />
            <TextBlock Text="Click or hover over a state to see the Toolkit MapTip." 
                Margin="25,20,25,25" TextAlignment="Center"  />
        </Grid>

        <Canvas HorizontalAlignment="Left" VerticalAlignment="Top" >
            <esriToolkit:MapTip x:Name="MyMapTip"  BorderBrush="#99000000" 
                BorderThickness="1" Title="State Info" VerticalOffset="10" 
                HorizontalOffset="10" Background="#DDFFFFFF" />
        </Canvas>

    </Grid>
</UserControl>
